{extend name="$adminPage"}

{block name="headStyle"}
<style type="text/css">
    .log-items {
        display: flex;
    }

    .log-items .item {
        line-height: 30px;
        display: flex;
        align-items: center;
        margin-left: 15px;
        font-weight: 600;
    }
</style>
{/block}

{block name="content"}
<form type="yunj" id="{$builderId}"></form>
<script type="text/javascript">
    layui.use(["jquery", 'yunj'], function () {
        let win = window;
        let doc = document;
        let $ = layui.jquery;

        // 处理auth_key字段的显示隐藏
        // function handleAuthKeyShowHide(form) {
        //     let enableLoginAuthObj = form.getFieldObj('enable_login_auth');
        //     let authKeyObj = form.getFieldObj('auth_key');
        //     if (enableLoginAuthObj.isChecked()) {
        //         authKeyObj.boxEl.show();
        //     } else {
        //         authKeyObj.boxEl.hide();
        //     }
        // }
        //
        // // 绑定渲染完成后的事件
        // $(doc).bind(`yunj_form_{$builderId}_render_done`, function (e, form) {
        //     handleAuthKeyShowHide(form);
        // });
        //
        // // 绑定登录授权点击事件
        // $(doc).bind(`yunj_form_{$builderId}_enable_login_auth_switch`, function (e, field) {
        //     let form = yunj.formObj(field.formId);
        //     handleAuthKeyShowHide(form);
        // });
    });
</script>
{/block}